<template>
  <div class="index">
    <div class="banner">
      <client-carousel arrows="always" router :url="picList" />
    </div>
    <div class="container topTab">
      <top-tab />
      <leftTabs />
    </div>
    <staticPop />
    <div class="min-container content">
      <content />
    </div>
    <service />
    <div class="cloudService">
      <CloudService />
    </div>
    <helpCenter />
    <div class="botInfo">
      <BotInfo />
    </div>
  </div>
</template>
<script setup lang="ts">
import { ref, onMounted } from "vue";
import TopTab from "./topTab/topTab.vue";
import Content from "./content/content.vue";
import service from "./service/service.vue";
import staticPop from "@/components/static/static.vue";
import leftTabs from "@/components/leftTabs/leftTabs.vue";
import helpCenter from "./helpCenter/helpCenter.vue";
import CloudService from "./cloudService/cloudService.vue";
import BotInfo from "./botInfo/botInfo.vue";
import { bannerList } from "@/api/other";

const picList = ref([]); // 轮播图

onMounted(() => {
  getBannerList();
});

// 获取轮播图
const getBannerList = () => {
  bannerList().then((res: any) => {
    picList.value = res.data;
  });
};
</script>
<style lang="less" scoped>
.index {
  .topTab {
    top: -60px;
  }
  .content {
    margin-top: -30px;
  }
  .cloudService {
    margin-bottom: 30px;
  }
}
</style>
